package com.service.Impl;

import java.util.ArrayList;
import java.util.List;

import com.service.AddressService;
import org.apache.ibatis.session.SqlSession;

import com.dao.AddressDAO;
import com.entity.Address;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class AddressServiceImpl implements AddressService {
	@Autowired
	private AddressDAO addressDAO;
	@Override
	public List<Address> showByUser(Integer userId) {
		List<Address> address=addressDAO.showByUser(userId);
		return address;
	}
	@Override
	public void insertAddress(Address address) {
			addressDAO.insertAddress(address);
	}
}
